package com.ruoyi.util.filetopdf.flyingsauser.config;

import java.io.File;
import java.io.IOException;
import freemarker.template.Configuration;

public class FreemarkerConfiguration {
	private static Configuration config = null;
	static {
		config = new Configuration(Configuration.DEFAULT_INCOMPATIBLE_IMPROVEMENTS);
		try {
			// 这里的模板位置写成了定制, 如果应用到项目里请将其放到配置文件里
			config.setDirectoryForTemplateLoading(new File("src/main/java/com/ruoyi/util/filetopdf/templates/"));
		} catch (IOException e) {
			e.printStackTrace();
		}
	}

	public static Configuration getConfiguation() {
		return config;
	}

}
